<%@page import="youleche.com.util.DateUtil"%>
<%@page import="youleche.com.model.MVehicleImageInfo"%>
<%@page import="java.util.List"%>
<%@page import="youleche.com.controler.controler.PageDataForBussinessControler"%>
<%@page import="youleche.com.model.MRentVehicleInfo"%>
<%@ page language="java" contentType="text/html;charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<%@include file="/WEB-INF/header.jsp" %>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>[${rentInfo.shopName}]${rentInfo.rentTitle}-美乐车网 </title>
<link  href="${ctx}/css/home.css"  rel="stylesheet"/>
<link  href="${ctx}/css/a.css"  rel="stylesheet"/>
<link  href="${ctx}/css/zcdetail.css"  rel="stylesheet"/>
<link href="${ctx}/image/meileche.jpg" rel="shortcut icon"/>
<script type="text/javascript" src="${ctx}/js/common/jquery-1.7.1.min.js"></script>
<script type="text/javascript" src="${ctx}/js/common/jquery.cookie.js"></script>
<script type="text/javascript" src="${ctx}/js/zcdetail.js"></script>
<style type="text/css">

 .small_time
 {
     float: left;
     padding-left: 20px;
     margin-right: 10px;
     background: url(image/main_title_bg.png?v=2012614) no-repeat;
     background-position: 0 0;
 }
 .small_people_num
 {
     float: left;
     padding-left: 20px;
     margin-right: 10px;
     background: url(image/main_title_bg.png?v=2012614) no-repeat;
     background-position: 0 -36px;
 }

    </style>
</head>
<body>
<%
	MRentVehicleInfo rentInfo = (MRentVehicleInfo) request.getAttribute("rentInfo");
	if(rentInfo == null){
		request.getRequestDispatcher("404.jsp").forward(request, response);
		return;
	}
	
	String rentType = "个人租车";
	String vehicleType = "自行车";
	if("1".equals(rentInfo.getRentType())){
		rentType = "商家租车("+rentInfo.getShopName()+")";
	}
	
	if("0".equals(rentInfo.getVehicleType())){
		vehicleType = "电动车";
	}
	
	List<MVehicleImageInfo> imgList= PageDataForBussinessControler.getImageInfoByVehicleId(rentInfo.getRentId());

%>
<%@include file="top.jsp" %>
<%@include file="nav.jsp" %>
<div style="margin-left:auto;margin-right:auto;width:1000px;margin-top:0px;border:1px #3CAC7E solid;padding-bottom:10px;">
        <img src="${ctx}/image/daohang.jpg" style="width:20px;height:20px;vertical-align: bottom;"/>
		<a href="http://www.meileche.com" style="color:#444;">美乐车网</a>
		->
		<a href="http://www.meileche.com/zcs.jsp" style="color:#444;">美乐租车</a>
		->
		<a href="http://www.meileche.com/rent.do?action=1&id=<%=rentInfo.getRentId()%>" style="color:#444;">租车详细信息</a>
		->
		[<%=rentInfo.getShopName()%>]<%=rentInfo.getRentTitle() %>
	
        </div>
<div style="width:1000px;margin-left:auto;margin-right:auto;min-height:100%;">
	
	<div style="width:1000px;height:50px;float:left;margin:10px 0px 20px 0px;">
		<ul class="more_info">
			<li><a href="zc.jsp">发布租车信息</a></li>
			<li><a href="zcs.jsp">查看其它租车信息</a></li>
			<%--<li><a><%= rentInfo.getA3()%>的车辆报价店铺</a></li>
			<li><a><%= rentInfo.getA3()%>的售后服务</a></li> --%>
		</ul>
	</div>
	<div style="float:left;width:1000px;font-size:10px;height:15px;line-height: 20px;margin-bottom:10px;color:#666;">
                <div class="small_time"><%=DateUtil.getDate("yyyy-MM-dd", rentInfo.getAddTime())%></div>
                <div class="small_people_num"><%= rentInfo.getA4() %></div>
             </div>
	<div style="width:700px;height:auto;float:left;">
		<div style="float:left;width:700px;heght: auto;line-height:25px;font-size:20px;">
			[<%=rentInfo.getShopName()%>]<%=rentInfo.getRentTitle() %>
		</div>
		<div style="float:left;width:700px;height: 30px;margin-top:10px;">
				<div style="float:left;width:100px;">租车价格:</div>
				<div style="float:left;width:600px;font-size:18px;color:#3CAC7E;">
					<div style="color:red;float:left;font-weight:bold;font-size:20px;"><%=rentInfo.getRentPrice()%></div>
					<div style="color:#444;float:left;font-size:12px;padding-top:5px;">&nbsp;&nbsp;元/日</div>
				</div>
		</div>
		<div style="float:left;width:700px;height: 30px;">
			<div style="float:left;width:100px;">&nbsp;&nbsp;联系人:</div><div style="float:left;width:600px;"><%=rentInfo.getLinkMan() %></div>
		</div>
		<div style="float:left;width:700px;height: 30px;">
			<div style="float:left;width:100px;">联系电话:</div><div style="float:left;width:600px;"><img src="che.do?action=3&callNum=<%=rentInfo.getLinkPhone()%>"/></div>
		</div>
		<div style="float:left;width:700px;height: auto;line-height:30px;">
			<div style="float:left;width:100px;">租车地址:</div><div style="float:left;width:600px;"><%=rentInfo.getRentAddress()%></div>
		</div>
		
		<div style="float:left;width:700px;height: 30px;">
			<div style="float:left;width:100px;">租车类型:</div><div style="float:left;width:600px;"><%=rentType%></div>
		</div>
		<div style="float:left;width:700px;height: 30px;">
			<div style="float:left;width:100px;">车辆类型:</div><div style="float:left;width:600px;"><img src="image/<%= "0".equals(rentInfo.getVehicleType()) ? "d_icon.jpg" : "z_icon.jpg"%>"/><%=vehicleType%></div>
		</div>
		<div style="float:left;width:700px;height: auto;">
			<div style="float:left;width:100px;">租车描述:</div><div style="float:left;width:600px;line-height:30px;"><%=rentInfo.getRentDesc()%></div>
		</div>
		
	</div>
	<div style="float:left;width:900px;padding-left:100px;height: 50px;padding-top:10px;font-size:20px;font-weight:bold;">
			租车联系我时，请说是在美乐车租车网上看到的，谢谢！
		</div>
	<div style="width:1000px;height:auto;float:left;margin:10px 0px 20px 0px;">
		<%
		if(imgList == null || imgList.size() == 0){
			 %>
			 <div style="float:left;width:200px;heght: 200px;">
				<img src="${ctx}/vehicleImage/nopic_200_200.jpg"/>
			</div>
			 <%
		}else{
			for(int i=0; i< imgList.size(); i ++){
				 %>
				 <div style="float:left;width:auto;heght: auto;margin:5px 0px 5px 0px;">
					<img style="max-width:1000px;" src="${ctx}/vehicleImage/<%=imgList.get(i).getImagePath()%>"/>
				</div>
				 <%
			 }
		}
		 
		%>		
	</div>
	<div style="float:left;width:1000px;margin-left:auto;margin-right:auto;border-top:1px solid #ccc;margin-top:5px;">
		<div  style="float:left;width:1000px;line-height:30px;font-size:14px;color:#444;">
			上一条租车信息：<a style="color:#444;font-size:14px;" href="rent.do?action=1&id=${preInfo.rentId}">[${preInfo.shopName}]${preInfo.rentTitle}</a>
		</div>
		<div  style="float:left;width:1000px;line-height:30px;font-size:14px;color:#444;">
			下一条租车信息：<a style="color:#444;font-size:14px;"  href="rent.do?action=1&id=${nextInfo.rentId}">[${nextInfo.shopName}]${nextInfo.rentTitle}</a>
		</div>
	</div>
</div>
<%@include file="foot.jsp" %>
</body>
</html>